package com.ruoyi.system.mapper;

import com.ruoyi.system.domain.TbComponentinfo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.HashMap;
import java.util.List;

/**
 * 基础数据Mapper接口
 *
 * @author wf
 * @date 2021-09-07
 */
@Mapper
public interface TbComponentinfoMapper {
    /**
     * 查询
     */
    TbComponentinfo selectTbComponentinfoById(Integer id);

    /**
     * 查询列表
     */
    List<TbComponentinfo> selectTbComponentinfoList(TbComponentinfo tbComponentinfo);

    /**
     * 新增
     */
    int insertTbComponentinfo(TbComponentinfo tbComponentinfo);

    /**
     * 修改
     */
    int updateTbComponentinfo(TbComponentinfo tbComponentinfo);

    /**
     * 删除
     */
    int deleteTbComponentinfoById(@Param("id") Integer id);

    /**
     * 批量删除
     */
    int deleteTbComponentinfoByIds(String[] ids);

    /**
     * 查询测试站以及数量
     */
    List<HashMap<String, Integer>> selectRegisterNoAndCount(TbComponentinfo tbComponentinfo);

    /**
     * 查询配件以及数量
     */
    List<HashMap<String, Integer>> partAndCountList(TbComponentinfo tbComponentinfo);

    List<String> selectStationNameList();
    List<String> selectReportNoList();
    List<String> selectRegisterNoList();
    List<String> selectDeviceNameList();
    List<String> selectPartNoList();
    List<String> selectPartSerialNoListList();
    List<String> selectModelList();
    List<String> selectManufacturerList();

    List<HashMap<String, Integer>> selectComponentinfoNoAndCount(TbComponentinfo tbComponentinfo);
}
